<?php
  require_once('./includes/db.php');
?>
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="">
    <meta name="author" content="">
    <link rel="shortcut icon" href="../../assets/ico/favicon.ico">

    <script src="js/jquery-1.9.1.js"></script>
    <!-- for validation start ----->
    <script src="js/validate/jquery.validate.js"></script>
    <script src="js/validate/additional-methods.js"></script>
    <script src="js/validate/register.js"></script>
    <!-- for validation end ----->



    <title>Register</title>

    <!-- Bootstrap core CSS -->
    <link href="./dist/css/bootstrap.min.css" rel="stylesheet">

    <!-- Custom styles for this template -->
    <link href="./css/jumbotron-narrow.css" rel="stylesheet">

    <link rel="stylesheet" type="text/css" media="screen" href="css/bootstrap-datetimepicker.css">


    <!-- Just for debugging purposes. Don't actually copy this line! -->
    <!--[if lt IE 9]><script src="../../assets/js/ie8-responsive-file-warning.js"></script><![endif]-->

    <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
    <!--[if lt IE 9]>
      <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
      <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->

    <style>
    .error {
      color: red;
    }
    </style>
  </head>

  <body>

    <div class="container">
      <div class="header">
        <ul class="nav nav-pills pull-right">



<?php


 if(!isset($_SESSION['id']) || empty($_SESSION['id'])){
echo '<li class="active"><a href="login.php">Login</a></li>
';
  } else {

echo <<<MSG
          <li class="dropdown btn btn-info">
            <a data-toggle="dropdown" class="dropdown-toggle" href="#">Manage Users<b class="caret"></b></a>
            <ul class="dropdown-menu btn btn-warning">
              <li class="panel panel-success"><a href="show_all_users.php">All Users</a></li>
              <li class="panel panel-success"><a href="register.php">Add New User</a></li>
            </ul>
          </li>

<li class="dropdown btn btn-info" >
                  <a data-toggle="dropdown" class=" dropdown-toggle " href="#">ADMIN<b class="caret"></b></a>
                  <ul class="dropdown-menu btn btn-warning">
                    <li class=""><a href="#">My Profile</a></li>
                    <li class=""><a href="change_password.php">Change Password</a></li>
                    <li class=""><a href="logout.php">Logout</a></li>
                  </ul>
                </li>
MSG;


  }
?>

        </ul>
        <h3 class="text-muted">Project name</h3>
      </div>
